// Copyright © SixtyFPS GmbH <info@slint-ui.com>
// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-commercial

TestCase := Rectangle {
    property<bool> condition;
    property<int> test_value: condition ? 1 : 2;
    property<bool> condition2;
    property<int> test_value2: condition ? condition2 ? 1 : 2 : condition2 ? 3 : 4;

    property<length> test_value3: false ? 0 : 12phx;
}
/*
```cpp
auto handle = TestCase::create();
const TestCase &instance = *handle;
instance.set_condition(true);
assert_eq(instance.get_test_value(), 1);
assert_eq(instance.get_test_value2(), 2);
instance.set_condition(false);
assert_eq(instance.get_test_value(), 2);
assert_eq(instance.get_test_value2(), 4);
instance.set_condition2(true);
assert_eq(instance.get_test_value2(), 3);
assert_eq(instance.get_test_value3(), 12.);
```


```rust
let instance = TestCase::new().unwrap();
instance.set_condition(true);
assert_eq!(instance.get_test_value(), 1);
assert_eq!(instance.get_test_value2(), 2);
instance.set_condition(false);
assert_eq!(instance.get_test_value(), 2);
assert_eq!(instance.get_test_value2(), 4);
instance.set_condition2(true);
assert_eq!(instance.get_test_value2(), 3);
assert_eq!(instance.get_test_value3(), 12.);
```

```js
var instance = new slint.TestCase({});
instance.condition = true;
assert.equal(instance.test_value, 1);
assert.equal(instance.test_value2, 2);
instance.condition = false;
assert.equal(instance.test_value, 2);
assert.equal(instance.test_value2, 4);
instance.condition2 = true;
assert.equal(instance.test_value2, 3);
assert.equal(instance.test_value3, 12);
```
*/
